package com.docmgmt.mvp.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.time.LocalDateTime;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

/**
 * <p>
 * RAGFlow同步日志表
 * </p>
 *
 * @author Dora
 */
@Getter
@Setter
@Accessors(chain = true)
@TableName("kb_sync_log")
public class SyncLogEntity implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 日志ID
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 同步任务ID
     */
    @TableField("task_id")
    private Long taskId;

    /**
     * 日志级别：info/warning/error
     */
    @TableField("level")
    private String level;

    /**
     * 日志消息
     */
    @TableField("message")
    private String message;

    /**
     * 详细信息（JSON格式）
     */
    @TableField("details")
    private String details;

    @TableField(value = "created_at", fill = FieldFill.INSERT)
    private LocalDateTime createdAt;
}
